home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 3 / Info_Mac_1994-01.iso / Applications / Address Book 3.6.5 / AdBk Utilities / H⁄C Addr to Text 1.5 / background_2665.txt < prev    next >
Text File  |  1990-08-06  |  7KB  |  275 lines

  1. -- background: 2665 from stack: in.5
  2. -- bmap block id: 2402
  3. -- flags: 0000
  4. -- background id: 0
  5. -- name: 
  6.  
  7.  
  8. -- part 7 (field)
  9. -- low flags: 00
  10. -- high flags: 0000
  11. -- rect: left=365 top=146 right=164 bottom=431
  12. -- title width / last selected line: 0
  13. -- icon id / first selected line: 0 / 0
  14. -- text alignment: 0
  15. -- font id: 0
  16. -- text size: 12
  17. -- style flags: 0
  18. -- line height: 16
  19. -- part name: message
  20.  
  21.  
  22. -- part 9 (button)
  23. -- low flags: 00
  24. -- high flags: 2000
  25. -- rect: left=20 top=37 right=71 bottom=59
  26. -- title width / last selected line: 0
  27. -- icon id / first selected line: 20098 / 20098
  28. -- text alignment: 1
  29. -- font id: 0
  30. -- text size: 12
  31. -- style flags: 0
  32. -- line height: 16
  33. -- part name: Home
  34. ----- HyperTalk script -----
  35. on mouseUp
  36.   visual effect iris close
  37.   go "Home"
  38. end mouseUp
  39.  
  40.  
  41.  
  42. -- part 10 (button)
  43. -- low flags: 00
  44. -- high flags: 2000
  45. -- rect: left=450 top=35 right=69 bottom=493
  46. -- title width / last selected line: 0
  47. -- icon id / first selected line: 17481 / 17481
  48. -- text alignment: 1
  49. -- font id: 0
  50. -- text size: 12
  51. -- style flags: 0
  52. -- line height: 16
  53. -- part name: Address
  54. ----- HyperTalk script -----
  55. on mouseUp
  56.   visual effect zoom open
  57.   go to stack "Address"
  58. end mouseUp
  59.  
  60.  
  61.  
  62. -- part 11 (button)
  63. -- low flags: 00
  64. -- high flags: 2000
  65. -- rect: left=413 top=28 right=61 bottom=447
  66. -- title width / last selected line: 0
  67. -- icon id / first selected line: 2478 / 2478
  68. -- text alignment: 1
  69. -- font id: 0
  70. -- text size: 12
  71. -- style flags: 0
  72. -- line height: 16
  73. -- part name: Do it!
  74. ----- HyperTalk script -----
  75. on mouseup
  76.   show card field "about" at 255,170
  77. end mouseup
  78.  
  79.  
  80.  
  81. -- part 12 (field)
  82. -- low flags: 00
  83. -- high flags: 0002
  84. -- rect: left=261 top=146 right=164 bottom=289
  85. -- title width / last selected line: 0
  86. -- icon id / first selected line: 0 / 0
  87. -- text alignment: 0
  88. -- font id: 0
  89. -- text size: 12
  90. -- style flags: 0
  91. -- line height: 16
  92. -- part name: Rec_del
  93.  
  94.  
  95. -- part 13 (button)
  96. -- low flags: 00
  97. -- high flags: A003
  98. -- rect: left=314 top=188 right=238 bottom=485
  99. -- title width / last selected line: 0
  100. -- icon id / first selected line: 0 / 0
  101. -- text alignment: 1
  102. -- font id: 0
  103. -- text size: 12
  104. -- style flags: 0
  105. -- line height: 16
  106. -- part name: Convert Address to Text
  107. ----- HyperTalk script -----
  108. on mouseUp
  109.   hide msg
  110.   put empty into field "message"
  111.   push card
  112.   if hilite of Background button "CR" is true then
  113.     put Return into field "rec_del"
  114.   else if hilite of Background button "Tab" is true then
  115.     put Tab into field "rec_del"
  116.   end if
  117.   put field "rec_del" into record_del
  118.   if hilite of card button "CR" is true then
  119.     put Return into field "field_del"
  120.   else if hilite of card button "Tab" is true then
  121.     put Tab into field "field_del"
  122.   end if
  123.   put field "field_del" into field_del
  124.   If field "Rec_del" is empty then
  125.     answer "You have not entered a Record Deliminater." with "OK"
  126.     exit mouseup
  127.   end if
  128.   If field "Field_del" is empty then
  129.     answer "You have not entered a Field Deliminater." with "OK"
  130.     exit mouseup
  131.   end if
  132.   If field_del = record_del then
  133.     answer "Record and Field Delims can't be the same." with "OK"
  134.     exit mouseup
  135.   end if
  136.   set cursor to 4
  137.   open file "Add->Text"
  138.   put empty
  139.   show message window at 19,298
  140.   set lockscreen to true
  141.   go to address
  142.   put the number of cards into cardnumber
  143.   put "Getting Addresses - Cards to go:" && cardnumber into msg
  144.   Repeat for cardnumber
  145.     put cardnumber into last word of msg
  146.     put 0 into linenumber
  147.     put 0 into wordnumber
  148.     repeat for the number of lines of field 1
  149.       add one to linenumber
  150.       If linenumber = 1 then
  151.         Put the number of words of line 1 of field 1 into wordnumber
  152.         If wordnumber = 0 then
  153.           write field_del & field_del to file "Add->Text"
  154.         else if wordnumber = 1 then
  155.           write field_del & word 1 of line 1 of field 1 & field_del to file "Add->Text"
  156.         else if wordnumber = 2 then
  157.           write word 1 of line 1 of field 1 & field_del & word 2 of line 1 of field 1 & field_del to file "Add->Text"
  158.         else if wordnumber > 2 then
  159.           write word 1 to wordnumber - 1 of line 1 of field 1 & field_del & last word of line 1 of field 1 & field_del to file "Add->Text"
  160.         end if
  161.       else
  162.         write line linenumber of field 1 & field_del to file "Add->text"
  163.       end if
  164.     end repeat
  165.     If linenumber < 7 then
  166.       repeat for 7 - linenumber
  167.         write field_del to file "Add->Text"
  168.       end repeat
  169.     end if
  170.     put 0 into linenumber
  171.     repeat for the number of lines of field 2
  172.       add one to linenumber
  173.       write line linenumber of field 2 & field_del to file "Add->Text"
  174.     end repeat
  175.     If linenumber < 3 then
  176.       repeat for 3 - linenumber
  177.         write field_del to file "Add->Text"
  178.       end repeat
  179.     end if
  180.     write record_del to file "Add->Text"
  181.     go next card
  182.     subtract 1 from cardnumber
  183.   end repeat
  184.   close file "Add->Text"
  185.   pop card
  186.   set lockscreen to false
  187.   hide msg
  188.   put "All Done!" into field "message"
  189. end mouseUp
  190.  
  191.  
  192.  
  193. -- part 14 (button)
  194. -- low flags: 00
  195. -- high flags: E006
  196. -- rect: left=56 top=145 right=165 bottom=94
  197. -- title width / last selected line: 0
  198. -- icon id / first selected line: 0 / 0
  199. -- text alignment: 1
  200. -- font id: 0
  201. -- text size: 12
  202. -- style flags: 0
  203. -- line height: 16
  204. -- part name: CR
  205. ----- HyperTalk script -----
  206. on mouseUp
  207.   if hilite of me is true then
  208.     hide msg
  209.     set hilite of background button "Tab" to false
  210.     set hilite of background button "Other" to false
  211.   end if
  212. end mouseUp
  213.  
  214.  
  215.  
  216. -- part 15 (button)
  217. -- low flags: 00
  218. -- high flags: A006
  219. -- rect: left=129 top=145 right=165 bottom=172
  220. -- title width / last selected line: 0
  221. -- icon id / first selected line: 0 / 0
  222. -- text alignment: 1
  223. -- font id: 0
  224. -- text size: 12
  225. -- style flags: 0
  226. -- line height: 16
  227. -- part name: Tab
  228. ----- HyperTalk script -----
  229. on mouseUp
  230.   if hilite of me is true then
  231.     hide msg
  232.     set hilite of background button "CR" to false
  233.     set hilite of background button "Other" to false
  234.   end if
  235. end mouseUp
  236.  
  237.  
  238.  
  239. -- part 16 (button)
  240. -- low flags: 00
  241. -- high flags: A006
  242. -- rect: left=196 top=145 right=165 bottom=254
  243. -- title width / last selected line: 0
  244. -- icon id / first selected line: 0 / 0
  245. -- text alignment: 1
  246. -- font id: 0
  247. -- text size: 12
  248. -- style flags: 0
  249. -- line height: 16
  250. -- part name: Other
  251. ----- HyperTalk script -----
  252. on mouseUp
  253.   if hilite of me is true then
  254.     set hilite of background button "CR" to false
  255.     set hilite of background button "Tab" to false
  256.     put empty into field "rec_del"
  257.     click at the location of field "rec_del"
  258.   end if
  259. end mouseUp
  260.  
  261.  
  262.  
  263. -- part 17 (field)
  264. -- low flags: 00
  265. -- high flags: 0002
  266. -- rect: left=261 top=266 right=284 bottom=289
  267. -- title width / last selected line: 0
  268. -- icon id / first selected line: 0 / 0
  269. -- text alignment: 0
  270. -- font id: 0
  271. -- text size: 12
  272. -- style flags: 0
  273. -- line height: 16
  274. -- part name: Field_del
  275.